#ifndef __WAVE__RENDER__H__
#define __WAVE__RENDER__H__
#include "IRender.h"
#include <string>
class WaveRender : public IRender
{
public:
	WaveRender(const std::string& name);

public:
	virtual void draw();
	virtual void idle();

private:
	void draw_wave();
	void init_wave(float w, float h, int wn, int hn);

private:
	PROGRAM_HANDLE mVertex;
	PROGRAM_HANDLE mFragment;
	CGprogram mVertexProgram;
	CGprogram mFragmentProgram;
	CGparameter mParamMvp;
	CGparameter mParamWorldMatrix;
	CGparameter mOutColor;
	CGparameter mShiness;
	float mProject[16];
	float mView[16];
	float mModel[16];
	float mModelViewProject[16];
	float mRotateAngleY;
	float mEyePosition[3];

	GLfloat* m_pkVertexs;
	GLuint* m_pkIndexes;
	GLuint m_Wn, m_Hn;

};
#endif//__WAVE__RENDER__H__